﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace 异步工具类
{
    class Program
    {
        static void Main(string[] args)
        {
            TaskTools task = new TaskTools(true);
            task.DelayedRun(3000, null, pnlMainFill2);
            task.DelayedRun(2000, null, () =>
            {
                pnlMainFill();
                //task.DelayedRun(1000, null, () =>
                //{
                //    pnlMainFill();
                //});

            });
            Console.Read();
        }
        public  static void pnlMainFill2()
        {

            Console.Write("333333333333");
        }
        public static  void  pnlMainFill()
        {

            Console.Write("121212121");
        }
    }
}
